package com.xbongbong.saas.enums;

import com.xbongbong.i18n.util.I18nMessageUtil;
import lombok.Getter;

import java.util.Objects;

/**
 * 合同产品类型
 * @author haibin.zhang
 * @version v1.0
 * @date 2019/5/17 14:14
 * @since v1.0
 */
@Getter
public enum ContractProductTypeEnum {
    CONTNRACT(XbbRefTypeEnum.CONTRACT.getCode(),"enum.contractProductType.name.contnract"),
    REFUND(XbbRefTypeEnum.REFUND.getCode(),"enum.contractProductType.name.refund"),
    ;
    private Integer code;
    private String name;

    ContractProductTypeEnum(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public String getName() {
        return I18nMessageUtil.getMessage(name);
    }
}
